import React, { useState } from 'react';

const detect = () => {
	const [c, setC] = useState(0);
	return (
		<div>
			<div onClick={() => setC(c + 1)}>inrease:{c}</div>
			<Child />
		</div>
	);
};

//memo ,useMemo,PureComponent

function Child({ }: {}) {
	console.log('child');
	return <div>this is child</div>;
}

export default detect;

// babel